import { createStore } from 'vuex';
import getters from './getter.js';

const files = require.context('./modules', false, /\.js$/)
const modules = {}

files.keys().forEach((key) => {
  console.log('key',key);
  modules[key.replace(/(\.\/|\.js)/g, '')] = files(key).default
})
Object.keys(modules).forEach((key) => {
  console.log('key',key);
  modules[key]['namespaced'] = true
})

export default createStore({
  state: {
  },
  mutations: {
  },
  getters,
  actions: {
  },
  modules: {
  }
})

